home *** CD-ROM | disk | FTP | other *** search
Text File | 1990-09-14 | 2.2 KB | 56 lines | [TEXT/MPS ] |
- This is a preliminary, non-functional example of an absolute pointing device driver
- for ADB. This example is provided primarily for developers of ADB devices, in that it demonstrates
- how to install an ADB device driver (aka Service routine, device handler) using the 'ADBS' resource
- mechanism.
-
- It does not currently conform to the proposed ADB tablet memory structure specification
- (Macintosh Technocal Note #266, 2/90) in at least the following ways:
-
- • The data structure is completely different. The driver only supports a place for device
- register 0 and 1, as well as some fields used internally by the driver.
-
- • The actual data sent by the device has not been addressed by the proposed spec, and the driver
- just assumes nine bytes of data in the following format from device register R0:
-
- Byte 1 = count (should be 8)
- Bytes 2 & 3 = state of switch(es)
- Bytes 4 & 5 = X coordinate
- Bytes 6 & 7 = Y coordinate
- Bytes 8 & 9 = Z coordinate
-
- The driver does not do anything with the Z coordinate.
-
- • There is no semaphore capability whereby the application and the driver know when each other
- is accessing/updating the coordinate or switch data.
-
-
-
- What this example DOES provide for the reader:
-
- • Demonstrates how to provide a driver in the 'ADBS' format, which is vaguely referenced in Inside
- Macintosh Volume 5. This more clearly describes, by example, the "initialization" and "driver code"
- sections of an 'ADBS' resource.
-
- • The installation section provides one example of how to try to reduce possible system heap
- fragmentation when installing the driver code.
-
- • The driver code provides an example of postioning the cursor, and posting mouse up/down events.
-
- • This example also shows how a jADBProc should handle de-allocating memory that the driver
- uses, as well as how to install the Proc.
-
- Other useful references:
-
- Macintosh
- Inside Macintosh Vol. 5 - Chapter 20, The Apple Desktop Bus
- Macintosh Hardware Reference - Chapter 4 - The ADB Interface
- Macintosh Technical notes #160 & 206
-
- Apple II & General
- Apple IIGS Hardware Reference Manual - Chapter 6
- Apple IIGS Firmware Reference Manual - Chapter 9
-
- General
- MacUser: 7/87, page 142 - Boarding the Bus, by Peter Baum
- Call A.P.P.L.E.: 6/87, page 24 - An Overview of Apple Desktop Bus, P. Baum
-